package com.qing.demo01.service;

import com.qing.demo01.dao.UserMapper;
import com.qing.demo01.entity.UserInfo;
import org.springframework.beans.factory.annotation.Autowired;

import java.util.List;

public class UserServiceImpl implements UserService {


	private UserMapper userMapper;


	public void setUserMapper(UserMapper userMapper) {
		this.userMapper = userMapper;
	}

	@Override
	public int add(UserInfo userInfo) {
		return userMapper.add(userInfo);
	}

	@Override
	public int update(UserInfo userInfo) {
		return userMapper.update(userInfo);
	}

	@Override
	public int delete(int id) {
		return userMapper.delete(id);
	}

	@Override
	public List<UserInfo> selectAll() {
		return userMapper.selectAll();
	}
}
